package com.dhl.fin.api.domain;

import com.dhl.fin.api.common.annotation.Excel;
import com.dhl.fin.api.common.annotation.ExcelTitle;
import com.dhl.fin.api.common.domain.BasicDomain;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.*;

/**
 * @author CuiJianbo
 * @since 2025/3/15
 */

/**
 * 业务记录
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Entity
@Excel
@Table(name = "t_business_record")
public class BusinessRecord extends BasicDomain {

    @ExcelTitle(name = "业务名字", width = 15, sort = 1)
    @Column(columnDefinition = "varchar(10)")
    private String businessName;

    @ExcelTitle(name = "业务简介", width = 25, sort = 2)
    @Column(columnDefinition = "varchar(200)")
    private String businessBrief;

    @ExcelTitle(name = "备注", width = 25, sort = 6)
    @Column(columnDefinition = "varchar(200)")
    private String remark;

    @ExcelTitle(name = "标签", width = 25, sort = 5)
    @Column(columnDefinition = "varchar(50)")
    private String tag;

    @ExcelTitle(name = "办理人", width = 15, sort = 3)
    @Column(columnDefinition = "varchar(10)")
    private String operator;

    @Transient
    @ExcelTitle(name = "办理时间", dateFormat = "yyyy-MM-dd HH:mm:ss", width = 20, sort = 4)
    private String createTimeStr;

    @ManyToOne
    @JoinColumn(name = "bank_account_id")
    private BankAccount bankAccount;


}
